package com.nmsl.registration.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.nmsl.registration.mapper.skxPrescriptionInfoMapper;
import com.nmsl.registration.domain.skxPrescriptionInfo;
import com.nmsl.registration.service.IskxPrescriptionInfoService;

/**
 * 患者处方信息Service业务层处理
 * 
 * @author skx
 * @date 2025-02-24
 */
@Service
public class skxPrescriptionInfoServiceImpl implements IskxPrescriptionInfoService 
{
    @Autowired
    private skxPrescriptionInfoMapper skxPrescriptionInfoMapper;

    /**
     * 查询患者处方信息
     * 
     * @param visitRecordId 患者处方信息主键
     * @return 患者处方信息
     */
    @Override
    public skxPrescriptionInfo selectskxPrescriptionInfoByPrescriptionInfoId(Long visitRecordId)
    {
        return skxPrescriptionInfoMapper.selectskxPrescriptionInfoByPrescriptionInfoId(visitRecordId);
    }

    /**
     * 查询患者处方信息列表
     * 
     * @param skxPrescriptionInfo 患者处方信息
     * @return 患者处方信息
     */
    @Override
    public List<skxPrescriptionInfo> selectskxPrescriptionInfoList(skxPrescriptionInfo skxPrescriptionInfo)
    {
        return skxPrescriptionInfoMapper.selectskxPrescriptionInfoList(skxPrescriptionInfo);
    }

    /**
     * 新增患者处方信息
     * 
     * @param skxPrescriptionInfo 患者处方信息
     * @return 结果
     */
    @Override
    public int insertskxPrescriptionInfo(skxPrescriptionInfo skxPrescriptionInfo)
    {
        return skxPrescriptionInfoMapper.insertskxPrescriptionInfo(skxPrescriptionInfo);
    }

    /**
     * 修改患者处方信息
     * 
     * @param skxPrescriptionInfo 患者处方信息
     * @return 结果
     */
    @Override
    public int updateskxPrescriptionInfo(skxPrescriptionInfo skxPrescriptionInfo)
    {
        return skxPrescriptionInfoMapper.updateskxPrescriptionInfo(skxPrescriptionInfo);
    }

    /**
     * 批量删除患者处方信息
     * 
     * @param prescriptionInfoIds 需要删除的患者处方信息主键
     * @return 结果
     */
    @Override
    public int deleteskxPrescriptionInfoByPrescriptionInfoIds(Long[] prescriptionInfoIds)
    {
        return skxPrescriptionInfoMapper.deleteskxPrescriptionInfoByPrescriptionInfoIds(prescriptionInfoIds);
    }

    /**
     * 删除患者处方信息信息
     * 
     * @param prescriptionInfoId 患者处方信息主键
     * @return 结果
     */
    @Override
    public int deleteskxPrescriptionInfoByPrescriptionInfoId(Long prescriptionInfoId)
    {
        return skxPrescriptionInfoMapper.deleteskxPrescriptionInfoByPrescriptionInfoId(prescriptionInfoId);
    }
}
